import { Block, Navigator, View, Image } from '@tarojs/components'
import { useRouter } from '@tarojs/taro';
import { useSelector, } from 'react-redux'
import { useEffect, useState } from 'react';
import { getCatalogContent } from '../../../../service/data'
import Header from '../../../../components/public/header/Header';
import './manual-horizontal.less'

function ManualHorizontal() {
  const router = useRouter()
  const cardId = useSelector(state => state.card.__cardId);
  const { pid, catalogId, staffCardId } = router.params
  // this.setData({
  //   pid: pid || catalogId,
  //   cardId: staffCardId || this.data.__cardId,
  //   manualLoading: true
  // })
  useEffect(() => {
    const q = async () => {
      const res = await getCatalogContent({
        cardId : staffCardId || cardId ,
        id: pid || catalogId
      })
      console.log(res);
    }
    q()
  }, [cardId, catalogId, pid, staffCardId])

  return (
    <Block>
      <Header title='横宣传册'></Header>
    </Block>
  )
}




export default ManualHorizontal

